import Vue from 'vue'
import VueRouter from 'vue-router'
import Login from '@/view/Login.vue'
import Main from '@/view/Main.vue'
import OutOfStorageList from '@/components/OutStorage'
import BatchInventory from '@/components/BatchInventory'
import OutOfStorageDetail from '@/view/outOfStorage/index'
import InventoryDetail from '@/view/inventory/index'

Vue.use(VueRouter)

export default new VueRouter({
  routes: [
    {
      path: '/',
      redirect: '/login'
    },
    {
      path: '/login',
      name: 'Login',
      component: Login,
      // meta: {
      //   "viewport": "width=device-width,initial-scale=1.0;user-scalable:false",
      // }
    },
    {
      path: '/main',
      name: 'Main',
      component: Main,
      // meta: {
      //   "viewport": "width=device-width,initial-scale=1.0;user-scalable:false",
      // }
      // children: [
      //   {
      //     path: '',
      //     name: 'OutOfStorage',
      //     component: OutOfStorage
      //   },
      //   {
      //     path: 'outOfStorage',
      //     name: 'OutOfStorage',
      //     component: OutOfStorage
      //   },
      //   {
      //     path: 'inventory',
      //     name: 'Inventory',
      //     component: Inventory
      //   },
      //   {
      //     path: 'mine',
      //     name: 'Mine',
      //     component: Mine
      //   }
      // ]
    },
    {
      path: '/outOfStorageDetail',
      name: 'OutOfStorageDetail',
      component: OutOfStorageDetail
    },
    {
      path: '/inventoryDetail',
      name: 'InventoryDetail',
      component: InventoryDetail
    },
    {
      path: '/outOfStorageList',
      name: 'OutOfStorageList',
      component: OutOfStorageList
    },
    {
      path: '/batchInventory',
      name: 'BatchInventory',
      component: BatchInventory
    }
  ]
})
